/**
 * 栈的实现
*/
#pragma once
#include "myVector.hpp"
#include <iostream>

namespace myStack
{
    template <class T>
    class Stack
    {
    public:
        // using stack_type = myVector::Vector<T>;
    public:
        T& top()
        {
            return *(_self.end() - 1);
        }
        void push(const T& value)
        {
            _self.push_back(value);
        }
        void pop()
        {
            _self.pop_back();
        }
        int size()
        {
            return _self.size();
        }
        bool empty()
        {
            return _self.empty();
        }

    private:
        // stack_type _self;
        myVector::Vector<T> _self;
    };
}